
// import { reactive } from '@vue/reactivity';
import { reactive } from './vue3/reactivity';


// composition API

const state = reactive({
  title: 'Vue3的响应式数据源码重写',
  age: 22,
  info: {
    time: '2022-1-4',
    friend: [
      {
        id: 1,
        name: '张三'
      },
      {
        id: 2,
        name: '李四'
      }
    ],
  },
  hobby: ['study', 'run', 'travel']

})

state.title = '修改的title';
state.age = 66;
state.info.friend[0].name = '名字';
state.info.friend.push({
  id: 3,
  name: '王五'
});
state.hobby.pop();
state.hobby[1] = 'play';

console.log(state);
